//
//  AboutMIDIViewCell.h
//  CommunityNannyO2O
//
//  Created by apple on 15/8/13.
//  Copyright (c) 2015年 Apple. All rights reserved.
//

#import "AboutMIDIViewCell.h"
#import "APIAdress.h"
#import "MBProgressHUD+YC.h"
#import "MJExtension.h"
#import "AccountTool.h"
#import "UIViewController+Create.h"
#import "CustomTextField.h"
#import "AppConfig.h"
#import "AboutMIDIViewCell.h"
#import "QXNetWorkTool.h"

@interface AboutMIDIViewCell()<QXNetWorkToolDelegate>

@end

@implementation AboutMIDIViewCell

+ (instancetype)cellWithTableView:(UITableView *)tableView
{
    static NSString *ID = @"AboutMIDIViewCell";
    AboutMIDIViewCell *cell = [tableView dequeueReusableCellWithIdentifier:ID];
    if (cell == nil) {
        
        cell = [[[NSBundle mainBundle] loadNibNamed:ID owner:nil options:nil]firstObject];
        
        [cell setSelectionStyle:UITableViewCellSelectionStyleNone];
    }
    
    return cell;
}

- (void)awakeFromNib
{
    UIView *view = [self viewWithTag:999];
    
    NSMutableArray *ary = [[NSMutableArray alloc] init];

    [ary addObject:[view viewWithTag:1]];
    [ary addObject:[view viewWithTag:2]];
    [ary addObject:[view viewWithTag:3]];
    [ary addObject:[view viewWithTag:4]];
    [ary addObject:[view viewWithTag:5]];
    [ary addObject:[view viewWithTag:6]];
    [ary addObject:[view viewWithTag:7]];
    [ary addObject:[view viewWithTag:8]];
    [ary addObject:[view viewWithTag:9]];
    [ary addObject:[view viewWithTag:10]];
    
    for (int i = 0; i < [ary count]; ++i)
    {
        UITapGestureRecognizer *tapGestureRecognizer = [[UITapGestureRecognizer alloc]initWithTarget:self action:@selector(tap:)];
        
        UIView *subView = [ary objectAtIndex:i];
        [subView addGestureRecognizer:tapGestureRecognizer];
    }
}

-(void)tap:(UITapGestureRecognizer *)recognizer
{
    if ([self.aboutMIDIViewCellDeletage respondsToSelector:@selector(setWeb:)])
    {
        
        [self.aboutMIDIViewCellDeletage setWeb:recognizer.view.tag];
    }
}

@end




















